/*  mem.h

    Memory manipulation functions

*/

/*
 *      C/C++ Run Time Library - Version 1.0
 *
 *      Copyright (c) 1987, 2002 by Borland Software Corporation
 *      All Rights Reserved.
 *
 */

/* $Revision: 1.1.8.2 $ */

#if !defined(__MEM_H)
#define __MEM_H

#ifndef ___STDDEF_H
#include <_stddef.h>
#endif

/* The libc prototypes for mem* funcs are in string.h */
#include _STD_HEADER_(string.h) 

#if !defined(RC_INVOKED)

#if defined(__STDC__)
#pragma warn -nak
#endif

#endif  /* !RC_INVOKED */


#ifdef __cplusplus
extern "C" {
#endif

/* Intrinsic functions, defined outside of the namespace */

void * __memchr__(const void * __s, int __c, _SIZE_T __n);
int    __memcmp__(const void * __s1, const void * __s2, _SIZE_T __n);
void * __memcpy__(void * __dest, const void * __src, _SIZE_T __n);
void * __memset__(void * __s, int __c, _SIZE_T __n);

#ifdef __cplusplus
namespace std {
#endif

#if defined(__cplusplus)
extern "C++"
{
          void * memchr(void *__s, int __c, _SIZE_T __n);
    const void * memchr(const void *__s, int __c, _SIZE_T __n);
          void * _wmemchr(void *__s, int __c, _SIZE_T __n);
    const void * _wmemchr(const void *__s, int __c, _SIZE_T __n);
}
#endif

#define movmem(src,dest,length) (void)memmove(dest,src,length)
#define setmem(dest,length,value) (void)memset(dest,value,length)

#if !defined(__STDC__) /* NON_ANSI  */
#define _fmemccpy memccpy
#define _fmemchr  memchr
#define _fmemcmp  memcmp
#define _fmemcpy  memcpy
#define _fmemicmp memicmp
#define _fmemmove memmove
#define _fmemset  memset
#define _fmovmem  movmem
#define _fsetmem  setmem
#endif /* __STDC__  */

#ifdef __cplusplus
} // std
} // extern "C"
#endif

#if !defined(RC_INVOKED)

#if defined(__STDC__)
#pragma warn .nak
#endif

#endif  /* !RC_INVOKED */


#endif  /* __MEM_H */
